package com.itheima.service.Impl;

import com.itheima.dao.Movie_InfoMapper;
import com.itheima.pojo.Movie_Counts;
import com.itheima.pojo.Movie_Info;
import com.itheima.service.Movie_InfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class Movie_InfoServiceImpl implements Movie_InfoService {
    @Autowired
    private Movie_InfoMapper movie_infoMapper;

    public void setMovie_infoMapper(Movie_InfoMapper movie_infoMapper) {
        this.movie_infoMapper = movie_infoMapper;
    }

    @Override
    public List<Movie_Counts> getMoviesByMovieCounts() {
        return movie_infoMapper.getMoviesByMovieCounts();
    }

    @Override
    public List<Movie_Info> getMoviesByMovieYeas() {
        return movie_infoMapper.getMoviesByMovieYeas();
    }

    @Override
    public List<Movie_Info> getMoviesInfoByKeyWords(String type, Integer year, String keyword) {
        return movie_infoMapper.getMoviesInfoByKeyWords(type,year,keyword);
    }


}
